function getGoodsPage(params) {
    return $axios({
        url: '/goods/page',
        method: 'get',
        params
    });
}

// 起售停售---批量起售停售接口
const goodsStatusByStatus = (params) => {
    return $axios({
        url: `/goods/status`,
        method: 'put',
        params
    })
}

const queryGoodsById = (id) => {
    return $axios({
        url: `/goods/${id}`,
        method: 'get'
    })
}

const editGoods = (params) => {
    return $axios({
        url: `/goods/edit`,
        method: 'put',
        data: {...params}
    })
}

const addGoods = (params) => {
    return $axios({
        url: `/goods/save`,
        method: 'post',
        data: {...params}
    })
}

const deleteGoods = (params) => {
    return $axios({
        url: `/goods`,
        method: 'delete',
        params
    })
}